home *** CD-ROM | disk | FTP | other *** search
/ Software Vault: The Gold Collection / Software Vault - The Gold Collection (American Databankers) (1993).ISO / cdr27 / gs26.zip / WATERFAL.PS < prev    next >
Text File  |  1993-04-16  |  3KB  |  75 lines

  1. %    Copyright (C) 1992, 1993 Aladdin Enterprises.  All rights reserved.
  2. %    Distributed by Free Software Foundation, Inc.
  3. %
  4. % This file is part of Ghostscript.
  5. %
  6. % Ghostscript is distributed in the hope that it will be useful, but
  7. % WITHOUT ANY WARRANTY.  No author or distributor accepts responsibility
  8. % to anyone for the consequences of using it or for whether it serves any
  9. % particular purpose or works at all, unless he says so in writing.  Refer
  10. % to the Ghostscript General Public License for full details.
  11. %
  12. % Everyone is granted permission to copy, modify and redistribute
  13. % Ghostscript, but only under the conditions described in the Ghostscript
  14. % General Public License.  A copy of this license is supposed to have been
  15. % given to you along with Ghostscript so you can know your rights and
  16. % responsibilities.  It should be in a file named COPYING.  Among other
  17. % things, the copyright notice and this notice must be preserved on all
  18. % copies.
  19.  
  20. % waterfal.ps
  21. % This file produces a 'waterfall' printout of fonts at various sizes.
  22.  
  23.  
  24. % Specify any desired set of up to 3 fonts here.
  25. /Fonts [/Palatino-Roman /Palatino-Italic /Palatino-Bold] def
  26.  
  27. % Specify any desired set of point sizes here.
  28. % The sum of the sizes should not exceed (roughly) 100.
  29. % For sizes larger than about 16, some characters may fall off the page.
  30. /Sizes [7 8 9 10 11 12 14 16] def
  31.  
  32. /eol
  33.  { currentfont /FontBBox get aload pop
  34.    exch pop sub exch pop 0 exch
  35.    currentfont /FontMatrix get dtransform
  36.    translate
  37.    0 0 moveto
  38.  } def
  39.  
  40. (landscap.ps) run
  41. clippath pathbbox newpath
  42. /ury exch def /urx exch def /lly exch def /llx exch def
  43. llx 18 add ury 18 sub translate
  44. % Read the current Y resolution without using Ghostscript-specific operators.
  45. gsave initmatrix 0 72 dtransform abs exch abs exch max grestore
  46. round cvi /dpi exch def
  47. QUIET not
  48.  { (Creating waterfall printout at ) print dpi =only ( DPI.\n) print flush
  49.  }
  50. if
  51.  
  52. newpath 0 setgray
  53. /Courier findfont 20 scalefont setfont
  54.  
  55. Fonts
  56.  { save exch
  57.    findfont /basefont exch def
  58.    basefont 20 scalefont setfont eol
  59.    basefont /FontName get =string cvs show
  60.    ( ) show dpi =string cvs show ( DPI) show
  61.    Sizes
  62.     { dup /size exch def basefont exch scalefont setfont eol
  63.       size =string cvs show ( ) show
  64.       (qwertyuiop-asdfghjkl_zxcvbnm ) show
  65.       (QWERTYUIOP+ASDFGHJKL/ZXCVBNM ) show
  66.       (1470258369 .,:;?!) show
  67.     } forall
  68.    matrix currentmatrix aload pop
  69.    7 -1 roll restore
  70.    6 array astore setmatrix
  71.  } forall
  72.  
  73. showpage
  74. quit
  75.